package com.demo.controller;


import com.baomidou.mybatisplus.core.metadata.IPage;
import com.demo.data.Result;
import com.demo.entity.TEsbUser;
import com.demo.service.ITEsbUserService;
import com.demo.service.impl.TEsbUserServiceImpl;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.*;

/**
 * <p>
 *  前端控制器
 * </p>
 *
 * @author author
 * @since 2022-08-04
 */
@RestController
@RequestMapping("/t-esb-user")
public class TEsbUserController {

    @Autowired
    private ITEsbUserService tEsbUserService;

    @GetMapping("/getPage")
    public Result getPage(@RequestParam(defaultValue = "1")Integer pageNum,
                          @RequestParam(defaultValue = "5")Integer pageSize){
        IPage<TEsbUser> iPage = tEsbUserService.selectPage(pageNum , pageSize);
        return Result.ok().setData(iPage);
    }
}
